#!/bin/sh
export LANG=zh_CN.UTF-8
echo $LANG
 
cd /data/console/zplay/shell/
formatday=`date --date="1 hour ago" +%Y-%m-%d`
hour=`date --date="1 hour ago" +%H`
if [ $1 ]; then
formatday=$1
fi
if [ $2 ]; then
hour=$2
fi
 

#ad pv
./download.sh zplay_ad_pv $formatday $hour
./analysis.sh zplay_ad_pv $formatday $hour
./database.sh zplay_ad_pv $formatday $hour

#ad click
./download.sh zplay_ad_click $formatday $hour
./analysis.sh zplay_ad_click $formatday $hour
./database.sh zplay_ad_click $formatday $hour

#ad clickd
./download.sh zplay_ad_clickd $formatday $hour
./analysis.sh zplay_ad_clickd $formatday $hour
./database.sh zplay_ad_clickd $formatday $hour

#ad download
./download.sh zplay_ad_download $formatday $hour
./analysis.sh zplay_ad_download $formatday $hour
./database.sh zplay_ad_download $formatday $hour

#ad activate
./download.sh zplay_ad_activate $formatday $hour
./analysis.sh zplay_ad_activate $formatday $hour
./database.sh zplay_ad_activate $formatday $hour

#wall pv
./download.sh zplay_pos_pv $formatday $hour
./analysis.sh zplay_pos_pv $formatday $hour
./database.sh zplay_pos_pv $formatday $hour 

./database.sh zplay_static_byhour $formatday $hour